package explorer;

import java.awt.Color;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.image.BufferedImage;

import javax.swing.JPanel;

public class IconLoader extends JPanel implements IIconLoader {

	private BufferedImage icon;
	private String iconType;
	
	protected IconLoader(String iconType) {
		
		this.iconType=iconType;
		
	}
	
	/* (non-Javadoc)
	 * @see explorer.IIconLoader#getIcon()
	 */
	@Override
	public BufferedImage getIcon(String iconType) {
		return icon;
	}

	@Override
	protected void paintComponent(Graphics graphics) {
		super.paintComponent(graphics);
	
		Graphics2D graphics2=(Graphics2D)graphics;
		graphics2.setBackground(Color.WHITE);

		graphics2.drawImage(icon,10,10, null);
	}
	
	
}
